body {
    font-family: "Microsoft YaHei", Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f9f9f9;
}

header {
    background-color: #2c3e50;
    color: white;
    text-align: center;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* 搜索容器 */
.search-container {
    display: flex;
    align-items: center;
    justify-content: center; /* 新增居中 */
    gap: 12px;
    width: auto; /* 改为自适应 */
    margin: 10px auto 0; /* 水平居中 */
}

#search-input {
    flex: 0 1 400px; /* 弹性基准400px */
    height: 40px;
    padding: 0 20px;
    border: 2px solid #4CAF50;
    border-radius: 25px;
    font-size: 16px;
}

#search-button {
    height: 40px;
    background: #4CAF50;
    color: white;
    border: none;
    padding: 0 25px;
    border-radius: 25px;
    cursor: pointer;
    transition: background 0.3s;
    flex-shrink: 0;
}

#search-button:hover {
    background: #45a049;
}

#publish-button {
    height: 40px;
    padding: 0 25px;
    border-radius: 25px;
    background-color: #3498db;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s ease;
    flex-shrink: 0;
}

#publish-button:hover {
    background-color: #2980b9;
}

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
}

.card {
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
    padding: 20px;
}

.card:hover {
    transform: translateY(-5px);
}

.card a {
    text-decoration: none;
    color: #333;
}

.card h2 {
    margin-top: 0;
    font-size: 1.2em;
}

.card p {
    margin: 10px 0 0;
    font-size: 0.9em;
    color: #666;
}

/* 通知样式 */
.notification {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 24px;
    border-radius: 8px;
    z-index: 1000;
    font-weight: 500;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.notification.hidden {
    display: none;
}

.notification.info {
    background: #2196F3;
    color: white;
}

.notification.error {
    background: #f44336;
    color: white;
}